import { IFeidaoAiBrowserComponent } from '@feidao/web/interfaces';
import show from '@feidao/web/atom/browser/ui/show';
import hide from '@feidao/web/atom/browser/ui/hide';


export default async function (fd: IFeidaoAiBrowserComponent, ...args: any[]) {

	//更换手机号
	const phone_dom = fd.data.node.querySelector<HTMLDivElement>('[data-feidao="phone"]');
	const wx_dom = fd.data.node.querySelector<HTMLDivElement>('[data-feidao="wx"]');

	hide(wx_dom);
	show(phone_dom);

	const npn_dom = fd.data.node.querySelector<HTMLInputElement>('[data-feidao-id="npn"]');
	const verificationcode_dom = fd.data.node.querySelector<HTMLInputElement>('[data-feidao-id="verificationcode"]');

	npn_dom.value = '';
	verificationcode_dom.value = '';
	const node = args[0].target as HTMLElement;
	node.classList.add('bg-e');
	node.classList.add('color-ff')
	console.log(node)
	const node1 = args[0].target.nextElementSibling as HTMLElement
	node1.classList.remove('bg-e')
	node1.classList.remove('color-ff')
}

